package Test.generatedConnectors;

//~--- non-JDK imports --------------------------------------------------------

import Test.Go;

import org.objectweb.fractal.api.NoSuchInterfaceException;
import org.objectweb.fractal.api.control.BindingController;
import org.objectweb.fractal.api.control.IllegalBindingException;
import org.objectweb.fractal.api.control.IllegalLifeCycleException;

//~--- JDK imports ------------------------------------------------------------

import java.util.HashMap;
import java.util.Map;

public class Connector346903545 implements Go, BindingController {
    private Map    bindings = new HashMap();
    private Object service;

    public String[] listFc() {
        return (String[]) bindings.keySet().toArray(new String[bindings.size()]);
    }

    public Object lookupFc(String itf) {
        return bindings.get(itf);
    }

    public void bindFc(String itf, Object value) {
        if (!itf.equals("component")) {
            bindings.put(itf, value);
        }
    }

    public void unbindFc(String clientItfName)
            throws NoSuchInterfaceException, IllegalBindingException, IllegalLifeCycleException {
        System.err.println("unbind");

        if (!(bindings.get(clientItfName) == null)) {
            bindings.remove(clientItfName);
        }
    }

    public String go(String a1) throws InterruptedException {
        return ((Go) service).go(a1);
    }
}


 
